Skip to content

Added cross-browser fullscreen behaviour#152

Open
MarielaTihova wants to merge 7 commits into
vnextfrom
mtihova/fix-147
Open

Added cross-browser fullscreen behaviour#152
MarielaTihova wants to merge 7 commits into
vnextfrom
mtihova/fix-147

Conversation

@MarielaTihova

Copy link
Copy Markdown

Resolves #147

@DiLazarova

This comment was marked as resolved.

@DiLazarova

This comment was marked as resolved.

@MarielaTihova

Copy link
Copy Markdown
Author

Slide effect

When you switch to full screen, a black page appears that slides to the left.

Screen.20Recording.202025-10-20.20at.2014.mp4
Screen capture test video: MacOS Sequoia 15.6.1 Safari 18.6

I have looked into this and it only happens when:

  • Browser is Safari
  • We have our browser on fullscreen mode already before clicking the fullscreen button. The difference is that once we have triggered the browser's native event for fullscreen (Ctrl + Command + F) and then trigger requestFullscreen(), Safari attempts to create a new OS-level fullscreen Space for the element, which causes the brief black flash/slide animation. This is expected behaviour in Safari/macOS and is not caused by the code we have in this repo.

There might be workarounds but they would require too much of a faking of fullscreen behaviour and I think it's not worth the trade-off.

@DiLazarova DiLazarova added design: verified ✅ status: verified Applies to PRs that have passed manual verification labels Oct 22, 2025
@dkamburov dkamburov requested a review from tishko0 October 30, 2025 11:35
@tishko0 tishko0 requested review from mddragnev and removed request for tishko0 October 30, 2025 12:25
@dkamburov

Copy link
Copy Markdown
Collaborator

@MarielaTihova please resolve conflicts

@kdinev

kdinev commented Jun 18, 2026

Copy link
Copy Markdown
Member

@ChronosSF Can this PR undergo a new review and be updated to the latest angular release. I notice NgZone reference in one of the components, which should probably be removed.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses cross-browser UI inconsistencies reported in #147 by improving fullscreen enter/exit detection (including Safari/WebKit events and F11 heuristics), adjusting fullscreen-related styling to avoid dark/black rendering, and updating Ignite UI-related dependencies across multiple example projects.

Changes:

  • Added WebKit fullscreen event handling and centralized fullscreen detection/toggling logic in the home view.
  • Updated home view styling for fullscreen and sub-header/tab areas to improve cross-browser rendering.
  • Updated Ignite UI Angular / Charts / Core / WebComponents dependency versions (and corresponding lockfiles) across several projects.

Reviewed changes

Copilot reviewed 10 out of 20 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/app/views/home/home.component.ts Adds cross-browser fullscreen event handling and updated fullscreen toggle logic.
src/app/views/home/home.component.scss Adjusts colors/backgrounds for sub-header and fullscreen states.
projects/sales-grid/src/app/sales-grid/sales-grid.component.ts Adds platform/browser detection for safer client-only UI behavior.
projects/sales-grid/src/app/sales-grid/sales-grid.component.html Conditionally renders tooltip-related UI in the browser.
projects/hr-portal/package-lock.json Lockfile metadata adjustment for hammerjs.
projects/fleet-management-grid/package-lock.json Bumps Ignite UI packages in lockfile.
projects/erp-hgrid/package-lock.json Bumps Ignite UI packages in lockfile.
projects/charts/step-chart/package.json Bumps Ignite UI and webcomponents dependency ranges.
projects/charts/step-chart/package-lock.json Updates resolved Ignite UI/webcomponents versions and peer metadata.
projects/charts/polar-chart/package.json Bumps Ignite UI and webcomponents dependency ranges.
projects/charts/polar-chart/package-lock.json Updates resolved Ignite UI/webcomponents versions and peer metadata.
projects/charts/pie-chart/package.json Bumps Ignite UI and webcomponents dependency ranges.
projects/charts/pie-chart/package-lock.json Updates resolved Ignite UI/webcomponents versions and peer metadata.
projects/charts/line-chart/package.json Bumps Ignite UI and webcomponents dependency ranges.
projects/charts/line-chart/package-lock.json Updates resolved Ignite UI/webcomponents versions and peer metadata.
projects/charts/column-chart/package.json Bumps Ignite UI and webcomponents dependency ranges.
projects/charts/column-chart/package-lock.json Updates resolved Ignite UI/webcomponents versions and peer metadata.
projects/charts/bar-chart/package.json Bumps Ignite UI and webcomponents dependency ranges.
projects/charts/bar-chart/package-lock.json Updates resolved Ignite UI/webcomponents versions and peer metadata.
package-lock.json Updates root resolved Ignite UI packages.
Files not reviewed (9)
  • projects/charts/bar-chart/package-lock.json: Generated file
  • projects/charts/column-chart/package-lock.json: Generated file
  • projects/charts/line-chart/package-lock.json: Generated file
  • projects/charts/pie-chart/package-lock.json: Generated file
  • projects/charts/polar-chart/package-lock.json: Generated file
  • projects/charts/step-chart/package-lock.json: Generated file
  • projects/erp-hgrid/package-lock.json: Generated file
  • projects/fleet-management-grid/package-lock.json: Generated file
  • projects/hr-portal/package-lock.json: Generated file

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 70 to 75
ngOnDestroy(): void {
if (!isPlatformBrowser(this.platformId)) return;

document.removeEventListener('fullscreenchange', this.onFullscreenChange);
document.addEventListener('webkitfullscreenchange', this.onFullscreenChange); // Safari / Mac
window.removeEventListener('resize', this.onResize);
Comment on lines 211 to +226
public async onToggleFullscreen(): Promise<void> {
if (!isPlatformBrowser(this.platformId)) return;

const el = this.fullscreenElement?.nativeElement;
if (!el) return;

if (!document.fullscreenElement && el?.requestFullscreen) {
await el.requestFullscreen();
this.isFullscreen = true;
} else if (document.exitFullscreen) {
await document.exitFullscreen();
this.isFullscreen = false;
try {
if (!this.isFullscreen) {
await this.requestFullscreen(el);
} else {
await this.exitFullscreen();
}

this.isFullscreen = this.isElementFullscreen();
this.cdr.detectChanges();
} catch (err) {
Comment on lines +227 to +228
background: white;
color: var(--ig-gray-900, black);
Comment on lines 235 to +236
background: white;
color: var(--ig-gray-900, black);
Comment on lines +5 to +7
<button *ngIf="isBrowser && configTooltipRef" igxButton="contained" style="margin-right: 10px;"
[igxToggleAction]="viewDropdown" [igxDropDownItemNavigation]="viewDropdown"
[igxTooltipTarget]="configTooltipRef">
<div #configTooltipRef="tooltip" igxTooltip>
Change pivot configuration.
</div>
<div *ngIf="isBrowser && configTooltipRef" #configTooltipRef="tooltip" igxTooltip>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

design: verified ✅ status: verified Applies to PRs that have passed manual verification

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Buttons and tabs are not displaying correctly in different browsers and platforms

5 participants